home *** CD-ROM | disk | FTP | other *** search
/ Disc to the Future 2 / Disc to the Future Part II Programmer's Reference (Wayzata Technology)(6013)(1992).bin / MAC / THINKC / 5 / UNUNIX1 / SOURCE_C / INIT.C next >
C/C++ Source or Header  |  1992-07-19  |  478b  |  21 lines

  1. #include <MacHeaders>
  2.  
  3. /*
  4. This wonderful little piece of code is copied right from the THINK C demo 'Bullseye'.
  5. It initialises all the Macintosh managers so the machine wont bomb when the app is
  6. run.  There's no guarantee that all the managers are represented here, but I think 
  7. there's all I'll ever need.
  8. */
  9.  
  10. void InitMacintosh(void)
  11.  
  12. {
  13.     InitGraf(&thePort);
  14.     InitFonts();
  15.     FlushEvents(everyEvent, 0);
  16.     InitWindows();
  17.     InitMenus();
  18.     TEInit();
  19.     InitDialogs(0L);
  20.     InitCursor();
  21. }